package com.siberhus.tdfl.transform;

import java.util.Properties;

/**
 * 
 * @author hussachai
 *
 */
public interface FieldSet {

	public int getFieldCount();
	
	public String[] getLabels();

	public boolean hasLabels();

	public String[] getValues();
	
	public String readString(int index);

	public String readString(int index, String defaultValue);

	public String readString(String label);

	public String readString(String label, String defaultValue);
	
	public String readRawString(int index);

	public String readRawString(String label);
	
	public <D> D read(Class<D> clazz, int index);
	
	public <D> D read(Class<D> clazz, int index, D defaultValue);

	public <D> D read(Class<D> clazz, String label);

	public <D> D read(Class<D> clazz, String label, D defaultValue);
	
	public <D>D[] readArray(Class<D> clazz, int index, String separator);
	
	public <D>D[] readArray(Class<D> clazz, String label, String separator);
	
	public Properties getProperties();
	
	public int indexOf(String label);
}
